-
Notifications
You must be signed in to change notification settings - Fork 2.6k
memory cleanup #4190
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
memory cleanup #4190
Conversation
|
@daniel-lxs please remove draft tag |
daniel-lxs
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @xyOz-dev, I took a look at your PR and left some questions.
Let me know your thoughts!
|
Looking over the requested changes now, not sure why it auto requested jr for review when i was fixing conflicts. |
ebbb19d to
d3eb802
Compare
daniel-lxs
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Applied the suggestions
LGTM
* memory cleaanup * forgot to run linter
* memory cleaanup * forgot to run linter
Related GitHub Issue
Closes: #3927 (Doesn't close, simply contributes to fixing by clearing up memory.)
Description
addresses potential memory leaks in the ChatView component, The main issues addressed include:
Type of Change
Important
Improves memory management in
ChatView.tsxby cleaning up timers and debounced functions, and optimizing dependencies.setTimeoutcalls inChatView.tsxto prevent memory leaks.debouncedscrollToBottomSmoothfunction to avoid memory retention.useEffectanduseCallbackdependency arrays to prevent unnecessary re-renders and stale closures inChatView.tsx.useDebounceEffectinChatView.tsxfor better handling of debounced effects.This description was created by
for 3d4aac31be0853e82d09e8e61b7c20833b23e83a. You can customize this summary. It will automatically update as commits are pushed.